import { defineStore } from 'pinia'

const teamStore = defineStore('team', {
  state: () => ({
    infoEdit: {
      tname: '',
      picture: '',
      oname: '',
      labelArr: [],
    },
  }),
  getters: {},
  actions: {
    changeInfo(payload: any) {
      this.infoEdit = { ...payload }
    },
  },
  persist: {
    enabled: true,
    strategies: [
      {
        key: 'my_team',
        storage: localStorage,
      },
    ],
  },
})

export default teamStore
